import request from '@/utils/request'

export const sellerApi = {
    /**
     *  删除
     * @returns
     */
    delete: (id) => {
        return request({
            url: '/manage/user/seller/delete',
            params: {id},
            method: 'get'
        })
    },

    /**
     *  确认审核
     * @returns
     */
    checkSeller: (data) => {
        return request({
            url: '/manage/user/seller/checkSeller',
            data,
            method: 'post'
        })
    },

    /**
     *  获取详细信息
     * @returns
     */
    getInfoById: (id) => {
        return request({
            url: '/manage/user/seller/getInfoById',
            params: {id},
            method: 'get'
        })
    },

    /**
     *  列表
     * @returns
     */
    getPage: (data) => {
        return request({
            url: '/manage/user/seller/getPage',
            data,
            method: 'post'
        })
    },

    /**
     *  新增商家
     * @returns
     */
    addSeller: (data) => {
        return request({
            url: '/manage/user/seller/addSeller',
            data,
            method: 'post'
        })
    },
    /**
     *  修改
     * @returns
     */
    edit: (data) => {
        return request({
            url: '/manage/user/seller/edit',
            data,
            method: 'post'
        })
    },

    /**
     *  查看商家身份证号
     * @returns
     */
    lookSellerIdCard: (sellerId) => {
        return request({
            url: '/manage/user/seller/lookSellerIdCard',
            params: {sellerId},
            method: 'get'
        })
    }
}
